package com.wang.service;

import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import com.wang.mapper.AddAutoSetDataMapper;
import com.wang.pojo.AddAutoSetData;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import org.springframework.transaction.annotation.Transactional;

@Service
@Transactional
public class AddAutoSetDataServiceImpl extends ServiceImpl<AddAutoSetDataMapper,AddAutoSetData> implements AddAutoSetDataService {

    @Autowired
    private AddAutoSetDataMapper addAutoSetDataMapper;

    @Override
    public AddAutoSetData selectBySetId(Integer setId) {
        return addAutoSetDataMapper.selectOne(new LambdaQueryWrapper<AddAutoSetData>().eq(AddAutoSetData::getSetId,setId));
    }

    @Override
    public AddAutoSetData selectByDevGId(String devGId) {
        return addAutoSetDataMapper.selectOne(new LambdaQueryWrapper<AddAutoSetData>().eq(AddAutoSetData::getDevGId,devGId));
    }
}
